package main

import (
  "fmt"
  "math/rand"
  "time"
)

func main() {
  rand.Seed(time.Now().UnixNano())
  var a map[string]int = make(map[string]int,1024)

  for i := 0; i < 128; i++ {
    key := fmt.Sprintf("stu%d",i)
    value := rand.Intn(1000)
    a[key] = value
  }

  for key, value := range a {
    //todo 每次遍历的key 出现的顺序都不一样
    fmt.Printf("map[%s]=%d\n",key, value)
  }
}
